package com.demo.module.allSimple.controller;

import com.demo.module.allSimple.service.AllSimpleSysUserService;
import com.demo.mybatis.entity.SysUser;
import com.mi.rule.security.resource.Res;
import com.mi.rule.security.resource.ResApi;
import com.mi.rule.util.project.SRS;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Res("模板项目管理")
@RestController
@RequestMapping("/allSimple/sysUser")
public class AllSimpleSysUserController {
    @Autowired
    private AllSimpleSysUserService allSimpleSysUserservice;

    @ResApi("新增")
    @RequestMapping("/insert")
    public SRS insert(@RequestBody SysUser param) {
        return allSimpleSysUserservice.insert(param);
    }

    @ResApi("删除")
    @RequestMapping({"/delete"})
    public SRS delete(@RequestBody Long[] ids) {
        return allSimpleSysUserservice.delete(ids);
    }

    @ResApi("修改")
    @RequestMapping("/update")
    public SRS update(@RequestBody SysUser param) {
        return allSimpleSysUserservice.update(param);
    }

    @ResApi("详情")
    @RequestMapping("/info")
    public SRS one(@RequestBody SRS param) {
        return allSimpleSysUserservice.info(param);
    }

    @ResApi("分页")
    @RequestMapping("/page")
    public SRS page(@RequestBody SRS param) {
        return allSimpleSysUserservice.page(param);
    }

    @ResApi("列表")
    @RequestMapping("/list")
    public SRS list(@RequestBody SRS param) {
        return allSimpleSysUserservice.list(param);
    }

}
